/**
 * @file panel.hpp
 * @author alex, 个人邮箱xueyuankui.good@163.com
 * @brief
 * @version 0.1
 * @date 2024-07-31
 *
 * @copyright Copyright (c) 2024
 *
 */
#pragma once
#ifndef __PANEL_HPP__
#define __PANEL_HPP__

#include <string>
#include <functional>
#include <map>

using func_cmd = std::function<void(int, char **)>;
using func_key = std::function<void()>;

void export_cmd_bind(std::string cmd, func_cmd fun);
void export_key_bind(char key, func_key fun);
int  ash_init();
void ash_spin_once();
#define ASH_EXPORT_CMD_BIND(cmd, fun) export_cmd_bind(cmd, fun);
#define ASH_EXPORT_KEY_BIND(key, fun) export_key_bind(key, fun);

#endif //